import { http, ResponseData } from '../http'
import { AxiosPromise } from 'axios'
 
interface ILogin {
  username: string;
  password: number | string
}
 
export const login = (data: ILogin): AxiosPromise<ResponseData> => {
  return http.request({
    method: 'POST',
    url: '/v1/user/login',
    data,
  })
}